Skip to content

feat(records): sync endpoint#2681

Closed
andersfylling wants to merge 4 commits into
masterfrom
feat/records-sync
Closed

feat(records): sync endpoint#2681
andersfylling wants to merge 4 commits into
masterfrom
feat/records-sync

Conversation

@andersfylling

@andersfylling andersfylling commented Jun 11, 2026

Copy link
Copy Markdown
Contributor

See https://docs.cognite.com/20230101/records/sync-records-from-a-stream

Since we don't have hierarchical rate limiting I've chosen a number that doesn't cause issue for any configuration: https://docs.cognite.com/api-reference/concepts/20230101/rate-limits#records-request-budgets-detailed-tables

@codecov

codecov Bot commented Jun 11, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 97.47475% with 5 lines in your changes missing coverage. Please review.
✅ Project coverage is 93.68%. Comparing base (9ecf95c) to head (ad587bc).

Files with missing lines Patch % Lines
...gnite/client/data_classes/data_modeling/records.py 96.29% 3 Missing ⚠️
cognite/client/_api/data_modeling/records.py 92.85% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #2681      +/-   ##
==========================================
- Coverage   93.70%   93.68%   -0.02%     
==========================================
  Files         503      503              
  Lines       50699    50883     +184     
==========================================
+ Hits        47505    47669     +164     
- Misses       3194     3214      +20     
Files with missing lines Coverage Δ
cognite/client/_sync_api/data_modeling/records.py 100.00% <100.00%> (ø)
...nite/client/data_classes/data_modeling/__init__.py 100.00% <ø> (ø)
cognite/client/utils/_concurrency.py 92.85% <100.00%> (+0.05%) ⬆️
...s_unit/test_api/test_data_modeling/test_records.py 100.00% <100.00%> (ø)
cognite/client/_api/data_modeling/records.py 96.36% <92.85%> (-3.64%) ⬇️
...gnite/client/data_classes/data_modeling/records.py 96.61% <96.29%> (-1.12%) ⬇️

... and 5 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@andersfylling andersfylling force-pushed the feat/records-list branch 2 times, most recently from eeb284f to 4f3a737 Compare June 15, 2026 08:21
@andersfylling andersfylling changed the base branch from feat/records-list to master June 21, 2026 08:32
@andersfylling andersfylling changed the title feat(records): add sync endpoint feat(records): sync endpoint Jun 21, 2026
andersfylling and others added 4 commits June 21, 2026 12:18
Co-authored-by: Cursor <cursoragent@cursor.com>
Separate initial sync from cursor-based continuation while sharing the request assembly and pagination through the internal _sync helper.

Co-authored-by: Cursor <cursoragent@cursor.com>
Deep-copy record property payloads when dumping so load/dump round-trip tests and callers cannot mutate the source instance through the returned dictionary.

Co-authored-by: Cursor <cursoragent@cursor.com>
Match the lowest read limit documented for Records by keeping the SDK's concurrent read requests capped at 4.

Co-authored-by: Cursor <cursoragent@cursor.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant